package me.wangqu.weiyouqu.web.rest.dto;

import java.time.LocalDate;
import javax.validation.constraints.*;
import java.io.Serializable;
import java.util.Objects;


/**
 * A DTO for the UserExtend entity.
 */
public class UserExtendDTO implements Serializable {

    private Long id;

    @NotNull
    private String login;

    @Pattern(regexp = "^[a-zA-z]+://[^\\s]*$")
    private String icon;

    private String name;

    @Min(value = 0)
    @Max(value = 2)
    private Integer gender;

    private LocalDate birthday;

    private String education;

    private String profession;

    private String income;

    private String interest;


    public Long getId() {
        return id;
    }

    public void setId(Long id) {
        this.id = id;
    }
    public String getLogin() {
        return login;
    }

    public void setLogin(String login) {
        this.login = login;
    }
    public String getIcon() {
        return icon;
    }

    public void setIcon(String icon) {
        this.icon = icon;
    }
    public String getName() {
        return name;
    }

    public void setName(String name) {
        this.name = name;
    }
    public Integer getGender() {
        return gender;
    }

    public void setGender(Integer gender) {
        this.gender = gender;
    }
    public LocalDate getBirthday() {
        return birthday;
    }

    public void setBirthday(LocalDate birthday) {
        this.birthday = birthday;
    }
    public String getEducation() {
        return education;
    }

    public void setEducation(String education) {
        this.education = education;
    }
    public String getProfession() {
        return profession;
    }

    public void setProfession(String profession) {
        this.profession = profession;
    }
    public String getIncome() {
        return income;
    }

    public void setIncome(String income) {
        this.income = income;
    }
    public String getInterest() {
        return interest;
    }

    public void setInterest(String interest) {
        this.interest = interest;
    }

    @Override
    public boolean equals(Object o) {
        if (this == o) {
            return true;
        }
        if (o == null || getClass() != o.getClass()) {
            return false;
        }

        UserExtendDTO userExtendDTO = (UserExtendDTO) o;

        if ( ! Objects.equals(id, userExtendDTO.id)) return false;

        return true;
    }

    @Override
    public int hashCode() {
        return Objects.hashCode(id);
    }

    @Override
    public String toString() {
        return "UserExtendDTO{" +
            "id=" + id +
            ", login='" + login + "'" +
            ", icon='" + icon + "'" +
            ", name='" + name + "'" +
            ", gender='" + gender + "'" +
            ", birthday='" + birthday + "'" +
            ", education='" + education + "'" +
            ", profession='" + profession + "'" +
            ", income='" + income + "'" +
            ", interest='" + interest + "'" +
            '}';
    }
}
